package com.xyoto.community.entity.main;

import com.xyoto.community.constant.FollowStatus;
import com.xyoto.community.entity.Base;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @Author lin
 * @Date 2021/10/1 23:00
 */
@Data
@ApiModel("话题关注表")
public class TopicFollow extends Base {

    @ApiModelProperty("用户id")
    private Integer userId;

    @ApiModelProperty("话题id")
    private Integer topicId;

    @ApiModelProperty("关注状态(1-关注 2-未关注)")
    private Short followStatus;

    public TopicFollow() {
        this.followStatus = FollowStatus.UN_FOLLOW;
    }

    /**
     *
     * @param userId 用户id
     * @param topicId 话题id
     */
    public TopicFollow(Integer userId, Integer topicId) {
        this();
        this.userId = userId;
        this.topicId = topicId;
    }
}
